/**
 * Created by larry.quns on 2022/1/8.
 */
//true 无异常
function clossArth() {
    logd("处理弹窗逻辑");
    // resurrectionEnergyPopover();
    clossDressUp();

    // 保存账户弹窗
    clossSaveLogin();
    return true;
}

function clossSaveLogin() {
    if (findNode(text("不保存"), true)) {
        logd("保存账户 关闭")
    }
    if (findImagePlus(["知道了1.png"], 636, 1270, 962, 1633)) {
        logd("知道了 关闭")
    }
    if (findImagePlus(["已签到1.png"],  343,1220,796,1616)) {
        logd("已签到 关闭")
    }
}


//复活能量弹窗
function resurrectionEnergyPopover() {
    logd("复活能量弹窗处理")
    let firstColor = "#DFDFDF-#101010";
    let multiColor = "-2|-285|#2FBF79-#101010,38|-295|#E9FFFA-#101010,0|-785|#333333-#101010,35|-800|#323232-#101010";
    let points = image.findMultiColorEx(firstColor, multiColor, 0.9, 427, 935, 637, 1820, 1, 1);
//这玩意是个数组
    if (points) {
        logd("points " + JSON.stringify(points));
    }
}

//装扮弹窗
function clossDressUp() {
    if (text("装扮中") && findNode(text("关闭"), true)) {
        logd("装扮弹窗关闭")
    }
    if (text("取消装扮") && findNode(text("关闭"), true)) {
        logd("装扮弹窗关闭")
    }
}
